﻿Public Class frmManages

    
    Public Sub New()

        ' This call is required by the designer.
        InitializeComponent()
        UI.FormatTapControl(tapManage)
        AddForm(trStock, frmProduct)
        AddForm(trSupplier, frmSupplier)
        AddForm(trMakeup, frmMakeupPrice)
        AddForm(trcorporate, frmCorporate)
        AddForm(tremployee, frmEmployees)
        AddForm(trexchange, frmExchange)
        ' Add any initialization after the InitializeComponent() call.
        loadbyuser()
    End Sub

    Private Sub loadbyuser()
        Dim ugroup = frmLogin.groupid
        Select Case ugroup
            Case 2
                tapManage.TabPages.Remove(trMakeup)
                tapManage.TabPages.Remove(trcorporate)
                tapManage.TabPages.Remove(tremployee)
                tapManage.TabPages.Remove(trexchange)
            Case 3
                tapManage.TabPages.Remove(trMakeup)
                tapManage.TabPages.Remove(trSupplier)
                tapManage.TabPages.Remove(tremployee)
                tapManage.TabPages.Remove(trexchange)
                tapManage.TabPages.Remove(trStock)

        End Select
    End Sub
End Class